package dancespeedymodelmysql

import (
	"gorm.io/gorm"
	"time"
)

// DanceActivitiesDrawPrizeConditions 抽奖活动条件
type DanceActivitiesDrawPrizeConditions struct {
	Id                        int64          `gorm:"primaryKey;autoIncrement;comment:id" json:"id"`
	ActivitiesId              int64          `json:"activitiesId" gorm:"column:activities_id;type:bigint;default:0;not null;comment:活动id"` // 开始时间
	TypeActivitiesOne         int            `json:"conditionsTypeOne" gorm:"column:conditions_type_one;type:bigint;default:0;not null;comment:一级类型"`
	TypeActivities            int            `json:"conditionsType" gorm:"column:conditions_type;type:tinyint;default:0;not null;comment:-1:星光值;80:碎片"`                       //奖品类型
	SplinterNum               int64          `json:"splinterNum" gorm:"column:splinter_num;type:bigint;default:0;not null;comment:碎片数量"`                                      // 碎片数量
	PrizeValue                int64          `json:"prizeValue" gorm:"column:prize_value;type:bigint;default:0;not null;comment:道具或者服饰编号，或者星光值"`                              // ElementNo
	ConditionsValueProportion int64          `json:"conditionsValueProportion" gorm:"column:conditions_value_proportion;type:bigint;default:0;not null;comment:抽奖比例，不能大于10万"` //
	ValidityPeriod            int64          `json:"validityPeriod" gorm:"column:validity_period;type:bigint;default:0;not null;comment:有效期"`                                 // 星光值
	Start                     int64          `json:"start" gorm:"column:start;type:bigint;default:0;not null;comment:命中开始区间"`                                                 // 命中区间开始，根据奖品命中概率计算
	End                       int64          `json:"end" gorm:"column:end;type:bigint;default:0;not null;comment:命中结束区间"`                                                     // 命中区间结束，根据奖品命中概率计算
	Tag                       int            `json:"tag" gorm:"column:tag;type:tinyint;default:0;not null;comment:0：1:一级,2:二级;3:三级;4:四级"`                                     // 星光值
	ExchangeNumber            int            `json:"exchangeNumber" gorm:"column:exchange_number;type:tinyint;default:0;not null;comment:0："`                                 // 兑换碎片数量，星光值和碎片为0
	PieceElementNo            int64          `json:"pieceElementNo" gorm:"column:piece_element_no;type:bigint;default:0;not null;comment:命中开始区间"`                             // 碎片编号
	CreatedId                 int64          `json:"created_id" gorm:"column:created_id;type:bigint;default:0;not null;comment:创建人id"`                                        // 创建人id
	CreatedAt                 time.Time      `json:"created_at" gorm:"column:created_at;type:datetime"`
	UpdatedAt                 time.Time      `json:"updated_at" gorm:"column:updated_at;type:datetime"`
	DeletedAt                 gorm.DeletedAt `gorm:"index;type:datetime" json:"-"`
}
